function show(a:any,b:any){

}
function printA(a:number,b:string,c:boolean,d:number[],e:any){

}
printA(1,"梦云",true,[1,2],12);
printA(1,"梦云",true,[1,2],"ass");

function printB(a:number,b:string,c?:any){}
printB(1,"梦云");
printB(1,"梦云",1);
printB(1,"梦云","a");

function printC(a:number,b:string,c?:boolean,d?:Array<number>,e?:any){}
printC(1,"梦云",true,[1,2],1);

function printD(a:number,b:string,c:boolean=true){}
printD(1,"梦云");
printD(1,"梦云",false);

function printE(a:number,b:string,c:boolean=true,d:Array<number>=[1,2],e:any=1){}
printE(1,"梦云",false,[1,2,3],2);
printE(1,"a",true,[1]);



function getParamsA():string{
    return "梦云";
}
var str1=getParamsA();

function getParamsB(flag:boolean):string{
    if(flag){
        return "真";
    }else{
        return "假";
    }
}

function getParamsC():number{
    try{
        return 123;
    }catch(error){
        throw error;
        // throw new Error();
    }
}

function getParamsD(){};
getParamsD();

function getParamsE(flag?:boolean):void{
    if(flag){
        console.log("真");
        return;
    }
    console.log("假");
}
getParamsE();

function getParamsF(flag?:boolean){
    if(flag){
        return "真";
    }else{
        return 123;
    }
}
getParamsF();